<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<title>
	</title>
	<script type="text/javascript" src="jQuery-1.11.3.min.js"></script>
	<script type="text/javascript" src="js/bootstrap.min.js"></script>
	<link rel="stylesheet" type="text/css" href="css/bootstrap.css">
</head>
<body>
<!-- Button trigger modal -->
<button type="button" class="btn btn-primary btn-lg" data-toggle="modal" data-target="#myModal">
  Launch demo modal
</button>

<!-- Modal -->
<div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
  <div class="modal-dialog" role="document">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
        <h4 class="modal-title" id="myModalLabel">Modal title</h4>
      </div>
      <div class="modal-body">
       	<input type="text" name="user">
      </div>
      <div class="modal-footer">
        <!-- <button type="button" class="btn btn-default" data-dismiss="modal">Close</button> -->
        <button type="button" class="btn btn-primary" id="chan" data-dismiss="modal">Save changes</button>
      </div>
    </div>
  </div>
</div>
</body>
</html>
<script type="text/javascript">
$().click();
	// $(function(){
		//消失时候触发
	// 	$("#myModal").on('hidden.bs.modal',function(){
	// 		console.log(222);
	// 	})
	// })
	//显示出来
	$("#myModal").modal({show:true})
</script>